<template>
  <div class="con">
    <section class="sec">
      <el-table
        :show-header="false"
        :data="tableData"
        center
        border
  
        style="width: 100%; margin-top: 10px;"
      >
        <el-table-column width="180" prop="name" center />
        <el-table-column prop="amount1" />
      </el-table>

    </section>
  </div>
</template>
<script>
import { carsOver } from '@/api/order'

export default {
  name: 'cars',
  props: ['accids'],
  data() {
    return {
      closeds: false,
      dataForm: {},
      taskNums: '',
      accidsWatchee:'',
      obj:''

    }
  },
  computed: {
  // 因为数据用到了dataform中的数据，所以写在了computed中
    tableData() {
      return [
        {
          name: '是否设置超时',
          amount1:this.obj.isOver
        },
        {
          name: '组长',
          amount1: this.obj.group_user
        }
      ]
    }
  },
 watch: {
    accids() {
      this.accidsWatchee = this.accids
      this.getDetail()
    }
  },
  created() {
    this.getDetail()
  },
  methods: {
    getDetail() {
      carsOver({ id:this.accids }).then(res => {
        console.log(8989)
        this.obj=res.data
        if(this.obj.task_minute>0){
          this.obj.isOver='是'
        }else{
           this.obj.isOver='否'
        }
      })
    }
  }
}
</script>
<style lang="scss" scoped>
.btnBox{
  width: 100%;
  display: flex;
  flex-direction: row-reverse;
  margin-top: 20px;
  // border-top:1px solid #eee;
}

</style>
